#!/bin/bash
#SBATCH -o logs/job.%j.out
#SBATCH -e logs/job.%j.error
#SBATCH -p debug
#SBATCH --qos=normal
#SBATCH -J CalcPi
#SBATCH --nodes={{ slurm_node_num }} 
#N/A SBATCH --ntasks-per-node=2

PATH=/usr/lib64/mpich/bin/:$PATH
export PATH

LD_LIBRARY_PATH=/usr/lib64/mpich/lib/:$LD_LIBRARY_PATH
export LD_LIBRARY_PATH

srun -N-99999 hostname |sort -n >hosts

mpirun -np {{ slurm_node_num }}  -machinefile ./hosts ./calc-pi-2 100000000000

